import java.util.*;

/**
 * @author LKQ
 * @date 2022/6/11 11:37
 * @description
 */
public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        while (sc.hasNextLine()) {
            String t = sc.nextLine();
            StringBuilder sb = new StringBuilder();
            for(int i = t.length() - 1; i >= 0; i--) {
                sb.append(t.charAt(i));
            }
            System.out.println(sb);
        }
    }
}
